<template>
  <el-dialog
    :title="title"
    :visible.sync="visible"
    :before-close="handleClose"
    :close-on-click-modal="false"
    :close-on-press-escape="false"
    width="960px"
    custom-class="edit-video"
  >
    <div style="display: flex">
      <div style="flex: 2;margin-right: 20px">
        <TabVideo :video="video" />
      </div>
      <div style="flex: 1">
        <Comment />
      </div>
    </div>
  </el-dialog>
</template>

<script>
import TabVideo from "./components/TabVideo";
import Comment from "./components/Comment";

export default {
  name: "EditVideo",
  components: {
    TabVideo,
    Comment
  },
  props: {
    visible: {
      type: Boolean,
      default: false
    },
    title: {
      type: String,
      default: "剪辑视频"
    },
    video: {
      type: Object,
      default: () => {
        return {
          url: "",
          type: "",
          pic: ""
        };
      }
    }
  },
  data() {
    return {};
  },

  methods: {
    // 关闭弹窗
    handleClose() {
      this.$emit("close");
    }
  }
};
</script>

<style lang="less" scoped></style>
